<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!doctype html>
<html class="no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>我的账号 已绑定</title>
<meta name="description" content="">
<meta name="keywords" content="">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta name="renderer" content="webkit">
<meta http-equiv="Cache-Control" content="no-siteapp" />
<meta name="format-detection" content="telephone=no" />
  <jsp:include page="/jsp/inc_head.jsp"></jsp:include>
<style>
  #zhezhao{
    background:#333;
    bottom: 0;
	width:100%;
    display: none;
    left: 0;
    opacity: 0.9;
    position: fixed;
    right: 0;
    top: 0;
    z-index: 1000;
	}
	.zzcltext{
		font-size:18px;
		color:#fff;
		margin-top: 200px;
		text-align:center;
		font-family: "Segoe UI","Lucida Grande",Helvetica,Arial,"Microsoft YaHei",FreeSans,Arimo,"Droid Sans","wenquanyi micro hei","Hiragino Sans GB","Hiragino Sans GB W3",FontAwesome,sans-serif;
	}
</style>
</head>

<body style="padding-bottom:50px;">
<div class="am-g">
    <div class="am-u-sm-12 am-pad-none">
    	<div class="am-u-sm-12 wdzh_lie">
            <div class="am-u-sm-8 am-pad-none">
            	<span id="phone" class="myzh_tel"></span>
            </div>
        	<div class="am-u-sm-4 am-pad-none am-text-right">
            	<button onclick="toAccountChange();" class="yzmsg"><span id="uptxtid" class="myzh_tel"></span></button>
            </div>
        </div>
    </div>
</div>
<div onclick="toUsertCenter();"  class="am-g btm_fixed">
	<div class="am-u-sm-12 am-text-center">
    	取消
    </div>
</div>
<script>
    var ajaxpath="${pageContext.request.contextPath}";
    $(function () {
          var url=ajaxpath+"/userCenter/queryMyphone.do?";
	      $.get(url, function(data){
              var phonetxt=data.phone;
              if(isNullOrEmpty(phonetxt)){
                  $("#phone").text("未绑定");
                  $("#uptxtid").text("去绑定");
              }else
              {
                  $("#phone").text(phonetxt);
                  $("#uptxtid").text("修改");
              }

	      });
    });
    function toAccountChange(){
         var phone=$("#phone").text();
         window.location.href = ajaxpath+"/client_toAccountchange.do?guid="+ new Date()+"&phone="+phone;
    }

    function toUsertCenter() {
        window.location.href = ajaxpath + "/client_toClientCenter.do?nowDateTime=" + new Date().getTime();
    }

    //true:是空
    function isNullOrEmpty(strVal) {
        if (strVal == null || strVal == undefined || strVal == '') {
            return true;
        } else {
            return false;
        }
    }

</script>
</body>
</html>
